<?php get_header(); ?>

	<?php
	query_posts('cat=23,20,17,15,11,9,16,14,8,12,21,22,61,7,10,13,18,19,24&order=DESC&posts_per_page=10');
	if (have_posts()) :
		?>
		<!-- Header Carousel -->
		<header id="myCarousel" class="carousel slide">
			<div class="carousel-inner">
				<?php while (have_posts()) : the_post(); ?>
					<?php
					if ( has_post_thumbnail() ) {
						?>
							<div class="item">
								<div class="fill" style="background-image:url('<?php echo get_the_post_thumbnail($post->ID, 'slider-home'); ?>');"></div>
								<div class="carousel-caption">
									<h2><?php echo $post->post_title ?></h2>
								</div>
							</div>
						<?php
					}
					?>
				<?php endwhile; ?>
			</div>
			<a class="left carousel-control" href="#myCarousel" data-slide="prev">
				<span class="icon-prev"></span>
			</a>
			<a class="right carousel-control" href="#myCarousel" data-slide="next">
				<span class="icon-next"></span>
			</a>
		</header>
	<?php endif; ?>
	<div class="publicidadeTopo">
		<a href="http://www.ocioso.com.br" target="_blank" title="Está no seu momento de descanso né? Entao clique aqui!">
			<img src="http://www.ocioso.com.br/imagens/parceiros/hotlink-ok/468p60.jpg" border="0" alt="Está no seu momento de descanso né? Entao clique aqui!" />
		</a>
		<a target="_blank" href="http://www.atoananet.com.br">
			<img src="http://www.atoananet.com.br/uploads/468x60.gif" alt="À toa na Net - Agregador de Conteúdo"/>
		</a>
	</div>




<section id="corpo" style="margin-bottom:0px; padding-bottom:0px;">	
<?php
	$n = rand(1, 2);
?>
<section id="banners" class="bg<?php echo $n ?>">
	<div class="wrapper">
		<div id="banner" style="position:relative;">
			<ul class="rslides" style="position:relative; max-height: 320px;">
				<?php
				query_posts('cat=23,20,17,15,11,9,16,14,8,12,21,22,61,7,10,13,18,19,24&order=DESC&posts_per_page=10');
				if (have_posts()) :
					while (have_posts()) : the_post();
					?>
					<?php $categoria_arr = get_the_category($post->ID); ?>
					<?php
						foreach ($categoria_arr as $cat) {
							if ($cat->category_parent > 0) {
								$link = get_category_link($cat->category_parent);
								$nome = get_the_category_by_ID($cat->category_parent);
							}
						}
					?>
						<li style="max-height: 320px; position:relative;">
							<div style="padding:10px 6px; width:100%; position:absolute; bottom:10px; background: #FFC600; -moz-box-sizing: border-box; -webkit-box-sizing: border-box; box-sizing: border-box;font-family: 'Source Sans Pro', sans-serif;">
								<a style="text-decoration:none; color:#fff; font-size:18px;" href="<?php echo get_permalink( $post->ID ); ?>"><?php echo $post->post_title; ?></a>
							</div>
							<a href="<?php echo get_permalink( $post->ID ); ?>" title="<?php echo $post->post_title ?>">
								<?php
									if ( has_post_thumbnail() ) {
										echo get_the_post_thumbnail($post->ID, 'slider-home');
									} else {
										if (class_exists('MultiPostThumbnails')) : MultiPostThumbnails::the_post_thumbnail(get_post_type(), 'destaque-image'); endif;	
									}
								?>
							</a>
						
						</li>
					<?php endwhile; ?>
				<?php endif; ?>
			</ul>
		</div>
		<div id="banner-pequeno" style="padding-top:25px;">
			<div id="podcast">
				Em Cartaz<!--Estréias-->
			</div>
			<div id="resenha">
				<div class="em-cartaz"></div>
				<div id="nav" class="color<?php echo $n ?>">
					<div id="prev"><<</div>
					<div id="next">>></div>
					<div class="clear"></div>
				</div>
				
			</div>
		</div>
		<div class="clear"></div>
	</div>
</section>
<section id="banner-shadow"></section>
	<div class="wrapper">
		<div class="bannersTopo">
			<div class="adsTopoHome adsGoogle" style="text-align:center;">
				<!-- TaxiCafé - Topo - Home -->
				<ins class="adsbygoogle"
					 style="display:inline-block;width:728px;height:90px"
					 data-ad-client="ca-pub-1415365042051363"
					 data-ad-slot="6842321134"></ins>
				<script>
				(adsbygoogle = window.adsbygoogle || []).push({});
				</script>
			</div>

			<div class="clear"></div>
		</div>
	
			<div class="box">
				<h2>Notícias</h2>
				<div class="lista">
					<?php
					query_posts('cat=7,10,13,18,19,24&order=DESC&posts_per_page=5');
					if (have_posts()) :
					$c = 0;
					while (have_posts()) : the_post();
						?>
							<?php $categoria_arr = get_the_category($post->ID); ?>
								<?php
									foreach ($categoria_arr as $cat) {
										if ($cat->category_parent > 0) {
											$categoria_nome = get_the_category_by_ID($cat->category_parent);
											$categoria_link = get_category_link($cat->category_parent);
										}
									}
								?>	
							<div class="item <?php echo $c == 0 ? 'principal' : '' ?>">
								<div class="image">
									<a href="<?php echo get_permalink( $post->ID ); ?>" title="<?php echo $post->post_title ?>">
										<?php
											if ( has_post_thumbnail() ) {
												if ($c == 0) {
													the_post_thumbnail("thumb-home-destaque");
												} else {
													the_post_thumbnail("thumb-home");
												}
											} else {
												if (class_exists('MultiPostThumbnails')) : MultiPostThumbnails::the_post_thumbnail(get_post_type(), 'destaque-image'); endif;	
											}
										?>
									</a>
								</div>
								<div class="corpo" style="">
									<h3 style="">
										<span class="label">
											<a href="<?php echo $categoria_link ?>" style="text-decoration:none;color:#fff;">
												<?php echo $categoria_nome ?>
											</a>
										</span>
										<a style="" href="<?php echo get_permalink( $post->ID ); ?>" title="<?php echo $post->post_title; ?>"><?php echo $post->post_title; ?></a>
									</h3>
									<div class="subtitle" style=""><?php the_subtitle(); ?></div>
								</div>
								<div class="clear"></div>
							</div>
						<?php $c++; ?>
				<?php endwhile; ?>
				<?php endif; ?>

					<div class="veja-mais-links" data-href="/todas-noticias"><i class="icon-plus"></i></div>
				</div>
			</div>
			<div class="box">
				<h2>Resenhas</h2>
				<div class="lista">
					<?php
					query_posts('cat=23,20,17,15,11,9&order=DESC&posts_per_page=5');
					if (have_posts()) :
					$c = 0;
					while (have_posts()) : the_post();
						?>
							<?php $categoria_arr = get_the_category($post->ID); ?>
								<?php
									foreach ($categoria_arr as $cat) {
										if ($cat->category_parent > 0) {
											$categoria_nome = get_the_category_by_ID($cat->category_parent);
											$categoria_link = get_category_link($cat->category_parent);
										}
									}
								?>	
							<div class="item <?php echo $c == 0 ? 'principal' : '' ?>">
								<div class="image">
									<a href="<?php echo get_permalink( $post->ID ); ?>" title="<?php echo $post->post_title ?>">
										<?php
											if ( has_post_thumbnail() ) {
												if ($c == 0) {
													the_post_thumbnail("thumb-home-destaque");
												} else {
													the_post_thumbnail("thumb-home");
												}
											} else {
												if (class_exists('MultiPostThumbnails')) : MultiPostThumbnails::the_post_thumbnail(get_post_type(), 'destaque-image'); endif;	
											}
										?>
									</a>
								</div>
								<div class="corpo" style="">
									<h3 style="">
										<span class="label">
											<a href="<?php echo $categoria_link ?>" style="text-decoration:none;color:#fff;">
												<?php echo $categoria_nome ?>
											</a>
										</span>
										<a style="" href="<?php echo get_permalink( $post->ID ); ?>" title="<?php echo $post->post_title; ?>"><?php echo $post->post_title; ?></a>
									</h3>
									<div class="subtitle" style=""><?php the_subtitle(); ?></div>
								</div>
								<div class="clear"></div>
							</div>
						<?php $c++; ?>
				<?php endwhile; ?>
				<?php endif; ?>

					<div class="veja-mais-links" data-href="/todas-resenhas"><i class="icon-plus"></i></div>
				</div>
			</div>
			<div class="box ultimos">
				<h2>Artigos</h2>
				<div class="lista">
					<?php
					query_posts('cat=16,14,8,12,21,22,61&order=DESC&posts_per_page=5');
					if (have_posts()) :
					$c = 0;
					while (have_posts()) : the_post();
						?>
							<?php $categoria_arr = get_the_category($post->ID); ?>
								<?php
									foreach ($categoria_arr as $cat) {
										if ($cat->category_parent > 0) {
											$categoria_nome = get_the_category_by_ID($cat->category_parent);
											$categoria_link = get_category_link($cat->category_parent);
										}
									}
								?>	
							<div class="item <?php echo $c == 0 ? 'principal' : '' ?>">
								<div class="image">
									<a href="<?php echo get_permalink( $post->ID ); ?>" title="<?php echo $post->post_title ?>">
										<?php
											if ( has_post_thumbnail() ) {
												if ($c == 0) {
													the_post_thumbnail("thumb-home-destaque");
												} else {
													the_post_thumbnail("thumb-home");
												}
											} else {
												if (class_exists('MultiPostThumbnails')) : MultiPostThumbnails::the_post_thumbnail(get_post_type(), 'destaque-image'); endif;	
											}
										?>
									</a>
								</div>
								<div class="corpo" style="">
									<h3 style="">
										<span class="label">
											<a href="<?php echo $categoria_link ?>" style="text-decoration:none;color:#fff;">
												<?php echo $categoria_nome ?>
											</a>
										</span>
										<a style="" href="<?php echo get_permalink( $post->ID ); ?>" title="<?php echo $post->post_title; ?>"><?php echo $post->post_title; ?></a>
									</h3>
									<div class="subtitle" style=""><?php the_subtitle(); ?></div>
								</div>
								<div class="clear"></div>
							</div>
						<?php $c++; ?>
				<?php endwhile; ?>
				<?php endif; ?>

					<div class="veja-mais-links" data-href="/todos-artigos"><i class="icon-plus"></i></div>
				</div>
			</div>
			<div class="clear"></div>
	</div>		
	<?php
	$n = rand(1, 2);
	?>
	<div class="bg<?php echo $n ?>" style="margin:20px 0px; width:100%;padding:20px 0px;">
		<div class="ocioso wrapper" style="overflow: hidden;">
			<iframe style="background: #FFF;border: none;overflow: hidden;width: 720px;height: 306px;float: left;" frameborder="0" scrolling="no" src="http://ocioso.com.br/troca-de-links/tag/id/cnvI0vmsXOkf20AKkVKgH8TwBlA36G_rB9RDT4ETsrD9qvxuLc1MMSwTh_MYcxkWQIth9tgeXWH1ow7pwbmPvS7aUioYjufxodH671r5ZrpWyQuHc0PVamdasTAaALxu8ztn08Hs-98VGuKUP3VhOLnUSAlGikOz50Vr7Gd2fklEQpAebvTgpkKIDMXT6f_bc-a_Ybhr17KkZ4cSv5hv_FB3MpJmxxBC5f99ib7UEELAe8aJCeAYIlI4S4rXlc48|dF3HfM9JEEteR5Nlxmk5FAfH2DIyV8tNH6rqCFvzhCA="></iframe>
			<div class="arrobaFooter adsGoogle" style="width: 336px;height: 280px;float: right;margin-right: 20px;margin-top: 10px;">
				<!-- TaxiCafé - 336x280 -->
				<ins class="adsbygoogle"
				style="display:inline-block;width:336px;height:280px"
				data-ad-client="ca-pub-1415365042051363"
				data-ad-slot="7121522739"></ins>
				<script>
				(adsbygoogle = window.adsbygoogle || []).push({});
				</script>
			</div>
		</div>
		<div class="clear"></div>
	</div>
</section>
<script>
$(".veja-mais-links").click(function(){
	window.location.href = "http://taxicafe.com.br/" + $(this).attr('data-href');
});
</script>
<style>#content {padding-bottom:0px;margin-bottom:0px;}</style>
<?php get_footer(); ?>